package com.mach.platform.service;

import com.mach.platform.repository.IotSpaceRepo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.transaction.Transactional;

/**
 * @author Administrator
 * @Description: 后台配置---图片配置
 * @Package: com.mach.platform.service
 * @time 2018/7/9 0009 14:26
 */
@Service
public class PicServiceImpl {

	@Autowired
	private IotSpaceRepo iotSpaceRepo;

	/**
	 * 保存上传图片的 信息到数据库
	 * @param spaceId
	 * @param picUrl
	 */
	@Transactional(rollbackOn = Exception.class)
	public void uploadPic(Long spaceId, String picUrl){
		iotSpaceRepo.updateLayoutPicUrl(spaceId, picUrl);
	}





}
